package com.host.dyyl.utils;

import android.content.Context;

import com.mynet.okhttp.DownloadFile;
import com.mynet.okhttp.listener.OkFileLisener;

import java.util.Map;

/**
 * @author
 * @describe
 * @fileName HomeHttp
 * @date 2017/10/16 14:19
 */

public class HomeHttp extends ProjectHttp {
    public HomeHttp(Context context) {
        super(context);
    }

    public void downloadFile(String url, String path, Map<String, String> headers, OkFileLisener<String> okFileLisener) {
        DownloadFile downloadFile = new DownloadFile();
        downloadFile.setUrl(url);
        downloadFile.setHeaders(headers);
        downloadFile.setFilePath(path);
        download(downloadFile, okFileLisener);
    }

}
